/**
 * 实有房屋GEO
 */
const { generateTableKeys, generateTableValues } = require('../function/common');

const FILENAME = __filename;

console.log(`============ 开始执行${FILENAME}脚本 ============`);

//起始索引
const START_INDEX = 201;

//表名
const TABLE_NAME = `actual_building_geo`;

//对应关系
const TABLE_MAPLIST = [
    {key: 'actual_building_id', value: '$1::bigint'},
    {key: 'adcode', value: '$2::varchar'},
    {key: 'province', value: '$3::varchar'},
    {key: 'city', value: '$4::varchar'},
    {key: 'district', value: '$5::varchar'},
    {key: 'town_ship', value: '$6::varchar'},
    {key: 'jurisdiction', value: '$7::varchar'},
    {key: 'detail_address', value: '$8::varchar'},
    {key: 'lng_x', value: '$9::numeric(9,6)'},
    {key: 'lat_y', value: '$10::numeric(8,6)'},
    {key: 'geo_hash', value: '$11::varchar'},
    {key: 'center_x', value: '$12::numeric(9,6)'},
    {key: 'center_y', value: '$13::numeric(8,6)'},
    {key: 'internal_coordinate_x', value: '$14::varchar'},
    {key: 'internal_coordinate_y', value: '$15::varchar'},
    {key: 'internal_coordinate_center_x', value: '$16::varchar'},
    {key: 'internal_coordinate_center_y', value: '$17::varchar'},
    {key: 'format_address', value: '$18::varchar'},
];

let TABLE_KEYS = generateTableKeys(TABLE_MAPLIST);
let TABLE_VALUES = generateTableValues(TABLE_MAPLIST);

console.log(`============ 执行${FILENAME}脚本结束 ============`);

module.exports = {
    START_INDEX,
    TABLE_NAME,
    TABLE_KEYS,
    TABLE_VALUES
}



